﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.GamerServices;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Media;
using The_Last_Knights.GUI;

namespace The_Last_Knights.GameScreen
{
    public class StaticScreen: Screen
    {
        protected static Border _header;
        protected static Border _footer;

        public StaticScreen(Game game, string ID, string background) 
            : base(game, ID, background)
        {            
        }

        private static Vector2 GetClientBound()
        {
            int width = (int) GameSettings.Resolution.X;
            int height = (int) GameSettings.Resolution.Y;
            return new Vector2(width, height);
        }

        public static void LoadTitle(Game game, string header)
        {
            Vector2 window = GetClientBound();
            _header = new Border(game, null, Vector2.Zero, window, null, header);            
        }

        public void LoadFooter(string footer)
        {
            throw new Exception("Chua cai dat");            
        }

        public override void Draw(GameTime gameTime)
        {
            base.Draw(gameTime);
            if (_header != null)
                _header.Draw(gameTime);
            if (_footer != null)
                _footer.Draw(gameTime);
        }
    }
}
